package date;

import java.math.BigDecimal;
import java.util.Calendar;
import java.util.Date;

/**
 * @author LIBOFEI
 * @ClassName Test1
 * @description
 * @date 2021/8/30 13:44
 * @Version 1.0
 **/
public class Test1 {

    public static void main(String[] args) {
        Calendar cal3 = Calendar.getInstance();
        cal3.setTime(new Date());
        int year = cal3.get(Calendar.YEAR);
        int month = cal3.get(Calendar.MONTH);
        System.out.println(year + "-" + month);


        BigDecimal a = new BigDecimal(5000 - 2250);
        BigDecimal b = new BigDecimal(5000 - 1);
        BigDecimal c = a.divide(b,4, BigDecimal.ROUND_HALF_UP);
        System.out.println(c.multiply(new BigDecimal(100)));
    }
}
